package com.kaifamiao.jdbc.d0908;

import java.sql.Connection;

public class Test {

    public static void main(String[] args) {
        String url = "jdbc:mysql://localhost:3306/kfm";
        Connection connection = DBUtil.getConnection(url, "root", "");

        int rows = DBUtil.update(connection, "update users set password = ?, username = ? where id = ?", "123456", "administrator", 1);

        DBUtil.update(connection, "update xxx");

        System.out.println(rows);

        DBUtil util = new DBUtil(url, "root", "");

        util.query("update xxx");
        util.query("update xxx");

//        util.close();

    }


}
